package com.kkshop.dao;

import java.io.Serializable;
import java.util.List;

import com.kkshop.domain.Persistent;

public interface DAO<K extends Serializable, V extends Persistent<? extends K>> {

    V findByPrimaryKey(K key) throws Exception;
    List<? extends V> findAll() throws Exception;
    List<? extends V> findMultipleWithWhere(String where) throws Exception;
    V findSingleWithWhere(String where) throws Exception;
    void save(V model) throws Exception;
    void update(V model) throws Exception;
    void delete(V model) throws Exception;
}
